# ifndef __HoluxWpo_H_
# define __HoluxWpo_H_

# ifdef _MSC_VER
#	pragma pack (push, 1)
# endif

const DWORD c_dwWpoWptSignature = 0x5C38A631;
const size_t c_cWpoMaxWaypoints = 500;

struct CWpoWaypointsHdr {
	DWORD dwSignature;

	WORD  wCurrentWaypoints;
	WORD  wNextWaypoints;

	WORD  wIdx [c_cWpoMaxWaypoints];
	BYTE  btUsed [c_cWpoMaxWaypoints];
};

struct CWpoWaypoint {
	char  strName [8];
	char  strComment [12];

	LONG  lX, lY;

	WORD  wVoiceIdx;
	WORD  wRoutesRefs;

	DWORD dwDate;
	DWORD dwTime;

	BYTE  btActive;

	BYTE  btReserved [3];
};

const DWORD c_dwWpoRoutesSignature = 0xD87F59F0;
const size_t c_cWpoMaxRoutes = 20;
const size_t c_cWpoMaxWaypointsInRoute = 30;

struct CWpoRoutesHdr {
	DWORD dwSignature;

	WORD wCurrentRoutes;
	WORD wNextRoutes;

	WORD wIdx [c_cWpoMaxRoutes];
	BYTE btUsed [c_cWpoMaxRoutes];

	WORD wNavigationRoute;

	WORD wReserved;
};

struct CWpoRoute {
	char  strName [8];
	char  strComment [12];

	WORD  wWaypoints;
	WORD  wWptIdx [c_cWpoMaxWaypointsInRoute];

	WORD  wReserved;

	DWORD dwDate;
	DWORD dwTime;
};

struct CWpoFile {
	CWpoWaypointsHdr WptHdr;
	CWpoWaypoint     Waypoints [c_cWpoMaxWaypoints];

	BYTE             btUnused [92];

	CWpoRoutesHdr    RoutesHdr;
	CWpoRoute        Routes [c_cWpoMaxRoutes];
};

# ifdef _MSC_VER
#	pragma pack (pop)
# endif

# endif // __HoluxWpo_H_